package com.thientan.utils

import java.security.MessageDigest

import org.apache.commons.codec.binary.Base64

import sun.misc.BASE64Encoder

/**
 * Used for encoding password.
 * */
class PasswordCodec {
	static encode = { str ->
		str.encodeAsBase64()
	}
	
	static decode = { theTarget ->
		new String(theTarget.decodeBase64())
	}
}
